<html xmlns="http://www.w3.org/1999/xhtml"
	xmlns:h="http://java.sun.com/jsf/html"
	xmlns:f="http://java.sun.com/jsf/core"
	xmlns:ui="http://java.sun.com/jsf/facelets"
	xmlns:p="http://primefaces.prime.com.tr/ui">
<ui:composition template="/pages/layout/mainLayout.xhtml">
	<ui:define name="bodyComUsuario">
		<div class="post"><p:panel
			header="#{bundle['locanet.locacoes.tituloCarrinho']}">
			<h:outputText
				value="#{bundle['locanet.entidades.lista.resultados.naoachado']}"
				style="color:red" rendered="#{empty locacaoBean.carroLocacao}" />
			<h:form>
				<p:dataTable value="#{locacaoBean.carroLocacao}"
					rendered="#{!empty locacaoBean.carroLocacao}" var="copia">
					<p:column>
						<h:form>
							<h:inputHidden value="#{copia.filme.id}" />
							<h:commandLink action="#{filmeBean.view}">
								<f:setPropertyActionListener value="#{copia.filme.id}"
									target="#{filmeBean.entity.id}" />
								<img class="img_busca" style="margin:0px" src="#{facesContext.externalContext.request.contextPath}/imgview?img=#{copia.filme.id}"/>
							</h:commandLink>
						</h:form>

						<div style="margin: 0px; text-align: right;"><h:commandLink
							action="#{locacaoBean.rmvDoCarrinho}">
							<f:setPropertyActionListener value="#{copia.id}"
								target="#{locacaoBean.copiaFilme.id}" />
							<img class="ico" style="float: right"
								src="#{facesContext.externalContext.request.contextPath}/images/ico_rmv.png" />
						</h:commandLink> <h:commandLink immediate="true" action="#{filmeBean.view}">
							<f:setPropertyActionListener value="#{copia.filme.id}"
								target="#{filmeBean.entity.id}" />
							<b><h:outputText value="#{copia.filme.titulo}" /></b>
							<br />
							<h:outputText value="#{ copia.filme.estilo.nome }" />
							<br />
							<h:outputText value="#{ copia.filme.dataChegada }">
								<f:convertDateTime pattern="dd/MM/yyyy" />
							</h:outputText>
							<br />
							<h:outputText value="#{bundle['locanet.Filme.signal']}" />
							<h:outputText value="#{copia.filme.precoLocacao}" />
						</h:commandLink></div>
					</p:column>
				</p:dataTable>
			</h:form>
			<h:form>
				<h:panelGrid columns="2">
					<h:column>
						<h:outputText value="#{bundle['locanet.total']}" />
						<h:outputText value="#{bundle['locanet.Filme.signal']}"
							style="text-align:right;color:red" />
					</h:column>
					<h:outputText value="#{locacacaoBean.precoTotal}" />
					<h:selectOneMenu rendered="#{loginBean.funcionario}" value="#{locacaoBean.id_cliente}">
						<f:selectItem />
						<f:selectItems value="#{locacaoBean.listaClientes}" var="c"
							itemValue="#{c.id}" itemLabel="#{c.nome}" />
					</h:selectOneMenu>
					<h:outputText rendered="#{loginBean.cliente}" />
					<h:commandButton action="#{locacaoBean.iniciaLocacao}"
						value="#{bundle['locanet.butoes.salvar']}" />
				</h:panelGrid>
			</h:form>
		</p:panel></div>
	</ui:define>
</ui:composition>
</html>
<!-- onclick="seleciona_cliente(getById('idCliente').value,getById('selecaoCliente'))" -->